<template>
  <div class="articlepage">
    <Zothertop topname="文章"></Zothertop>
    <div class="maincon">
      <div class="activecon clearfix">
        <div class="activecon-top clearfix">
          <img src="../../images/IMG_liaotianjiemian_1.png" height="140" width="140">
          <span>{{data.username}}<p>{{data.fan}}</p></span>
          <button type="button" class="btn">关注ta</button>
        </div>
        <div class="activecon-con">
          <img :src="data.img">
        </div>
      </div>
      <div class="comment">
        <div class="comment-top clearfix">
          <div class="day clearfix">
            <img :src="data.dayimg">
            <div class="text">{{data.daytxt}}</div>
          </div>
          <div class="look clearfix">
            <img :src="data.lookimg">
            <div class="text">{{data.looktxt}}</div>
          </div>
          <div class="comment-txt clearfix">
            <img :src="data.commentimg">
            <div class="text">{{data.commenttxt}}</div>
          </div>
          <div class="love clearfix">
            <img :src="data.loveimg">
            <div class="text">{{data.lovetxt}}</div>
          </div>
        </div>
        <div class="comment-con">
          <div class="minshow clearfix" v-for="(item,index) in data.personcomment" :key='index'>
            <div class="times">{{item.times}}</div>
            <img :src="item.portrait">
            <div class="txt">
              <span>{{item.username}}</span>
              <b>{{item.content}}</b>
            </div>
          </div>
          <hr>
          <div class="allcomment"><router-link to="/comment">全部评论</router-link></div>
        </div>
      </div>
    </div>
    <Zcommentbottom></Zcommentbottom>
    <div class="bg"></div>
  </div>
</template>
<script>
import Zothertop from "../../components/zothertop.vue"
import Zcommentbottom from "../../components/zcommentbottom.vue"
export default {
  name:'articlepage',
  data(){
      return{
        data:{}
      }
  },
  components:{
    Zothertop,
    Zcommentbottom
  },
  created(){
    this.$http.get(this.$store.state.host+'/love/articlepage')
    .then(res=>{
      this.data = res.data
    })
  }
}
</script>
<style lang="less" scoped>
  .maincon{
    float: left;
    margin: 20/75rem 20/75rem;
  }  
  .bg{
    height: 188/75rem;
    background: #ff406f;
  }
  .activecon{
    background-color: #fff;
    padding: 30/75rem 20/75rem 32/75rem 20/75rem;
    box-shadow: 2/75rem 2/75rem 9/75rem rgba(0,0,0,0.1);
    border-radius: 10/75rem;
    margin-top: 40/75rem;
    position: relative;
  }
  .activecon-top img{
    position:absolute;
    top:-22/75rem;
    left:20/75rem;
  }
  .activecon-top span{
    font-size: 28/75rem;
    margin-left: 162/75rem;
    float: left;
    text-align: left;
  }
  .activecon-top span p{
    margin:10/75rem 0;
  }
  .activecon-top .btn{
    background-color: #fff;
    font-size: 18/75rem;
    border: 1px solid #808080;
    width: 93/75rem;
    height:32/75rem;
    line-height:30/75rem;
    border-radius:32/75rem;
    float: right;
    margin-right: 7/75rem;
  }
  .activecon-con{
    height: 352/75rem;
    margin-bottom: 38/75rem;
  }
  .activecon-con img{
    margin-top: 40/75rem;
    height: 352/75rem;
  }
.comment{
  background-color: #fff;
  padding-top:25/75rem;
}
 .comment-top img{
    width: 20/75rem;
    height: 20/75rem;
    display: block;
    float: left;
 }
 .day,.look{
  float: left;
  font-size: 18/75rem;
  margin-right:30/75rem
 }
 .comment-txt,.love{
  float: right;
  font-size: 18/75rem;
  margin-left:30/75rem
 }
  .text{
    float: left;
    margin:0 5/75rem;
  }
.minshow{
    margin: 25/75rem 0;
    background-color: #fff;
  }
  .minshow img{
    display: block;
    float: left;
  }
  .txt{
    float: left;
    margin-left: 40/75rem
  }
  .txt span{
    color: #333;
    font-size: 24/75rem;
    display: block;
    text-align: left;
  }
  .txt b{
    color: #333;
    font-size: 18/75rem;
    margin: 30/75rem 0;
    display: block;
  }
  .times{
    float: right;
    font-size:18/75rem;
    margin:0 5/75rem;
  }
  hr{
    margin:20/75rem
  }
  .allcomment{
    color:#ff406F;
    font-size:24/75rem;
    padding-bottom: 20/75rem;
    margin-bottom:90/75rem;
    text-align: center;
  }

</style>
